﻿using UnityEngine;
using System.Collections;

public class BulletMove1 : MonoBehaviour {
	
	public float bulletSpeed = 0.05f;
	public float direction;
	public GameObject myPlayer1;
	
	void Start(){
		myPlayer1 = GameObject.FindWithTag("Player1");
		direction = myPlayer1.GetComponent<Player1Controller1>().playerScale.x;
	}
	
	void FixedUpdate () 
	{
		Debug.Log ("Moving");
		rigidbody2D.velocity = new Vector2(bulletSpeed*direction, rigidbody2D.velocity.y);

	}
	
}
